//
// <copyright file="Default.aspx.cs" company="Microsoft">
//     Copyright (c) Microsoft Corporation.  All rights reserved.
// </copyright>
//
using System;
using System.Linq;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using ZeCloud.Resto55.Business.Table;
using ZeCloud.Resto55.Business;

public partial class Default_aspx  : System.Web.UI.Page {


    protected void Page_Load(object sender, EventArgs e)
    {
        RestoService restoService = BusinessFacade.CreerFacade().GetRestoService();
        var restos = (from r in restoService.Restos
                          select r).AsEnumerable();

        var lastRestos = from r in restos
                          orderby r.Timestamp descending
                          select r;

        DataList1.DataSource = lastRestos.Take(5);
        DataList1.DataBind();
        
    }
}